package com.hzzc;

public class BizException extends RuntimeException {

    private int code = EnumResultCode.ERROR.getCode();

    public BizException(String message, int code) {
        super(message);
        this.code = code;
    }

    public BizException(String message, Throwable cause, int code) {
        super(message, cause);
        this.code = code;
    }

    public BizException(String message, Throwable cause) {
        super(message, cause);
    }

    public BizException(String message) {
        super(message);
    }

    public BizException() {
    }

    public int getCode() {
        return code;
    }

    public BizException setCode(int code) {
        this.code = code;
        return this;
    }
}
